home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
The CICA Windows Explosion!
/
The CICA Windows Explosion! - Disc 2.iso
/
programr
/
mathstud.zip
/
WSINA.M
< prev
next >
Wrap
Text File
|
1993-03-23
|
551b
|
24 lines
function y = wsina(n,np,woff)
%y=wsina(n,na, woff)
%create a family of sine windows
% n - number of points
% np - power of sin (default is one)
% Popular values of na are 1, 2, 3, 4
% woff - offset (default 0)
%
% sine lobe window is generated by wsina(n)
% S.Halevy 7/31/92
% Copyright (c) 1992 by the MathWizards
%y = sinw(n,0.5); % last sample matched to the first
y = sin(pi*x01(n)); % for MATLAB compatibility
if nargin>1
y = y .^ np;
end
if nargin>2
y = woff + (1-woff)*y;
end